﻿using System;
using Epitech.Krisk.Xna.ScreenManagerLib.ScreenManager;
using Microsoft.Xna.Framework;
using Epitech.Krisk.Xna.ScreenManagerLib;
using Microsoft.Xna.Framework.Graphics;

namespace Epitech.Krisk.Xna.UI.Game.InGame
{
    class GameMap : AGameObject
    {
        Texture2D _map;

        public GameMap()
        {

        }

        public override void Draw(GameTime gameTime)
        {
            Rectangle winSize = new Rectangle(0, 0, ViewPort.Width, ViewPort.Height);

            SpriteBatch.Begin();
            SpriteBatch.Draw(_map, winSize, Color.White);
            SpriteBatch.End();
        }

        public override void HandleInput(InputState input)
        {
        }

        public override void LoadContent()
        {
            if (Content == null)
                throw new Exception("Null Content manager.");
            _map = Content.Load<Texture2D>("Game/GameMap");
        }

        public override void UnloadContent()
        {
        }

        public override void Update(GameTime gameTime, bool otherScreenHasFocus, bool coveredByOtherScreen)
        {
        }
    }
}
